package com.uchiyou.walletwrapper.controller;

import com.uchiyou.walletwrapper.util.AddressUtil;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping(path = "/address")
public class AddressController {

    @PostMapping(path = "/new/bylabel")
    public String get(@RequestParam("label") String label){
        return AddressUtil.getNewaddress(label);
    }

    @PostMapping(path = "/list/bylabel")
    public String listAddressUnderLabel(@RequestParam("label") String label){
        return AddressUtil.getaddressesbylabel(label);
    }



}
